package com.tjetc.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.ibatis.ognl.internal.entry.CacheEntry;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
//配置实体类对应表名称
@TableName("cities")
public class City {
    @TableId(value = "city_id", type = IdType.AUTO)
    private Long id;
    private String cityName;
    private Province province;
    private List<String> imagePath;
    //java实体类驼峰命名与数据库字段字段下划线 自动映射（得益于map-underscore-to-camel-case: true这个配置）
    private BigDecimal centerLat; // 这里用 BigDecimal
    private BigDecimal centerLng;
    private Long code;
    private String trend;
    private Long likes;
    private Long lastLikes;
    private String description;
    private Long hotness;
    private TravelTheme travelTheme;
}
